<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Incluir Autor</title>
	<link rel="stylesheet" href="css/cupertino/jquery-ui-1.10.3.custom.css" type="text/css" media="screen, projection" />
	
	<script language="javascript" type="text/javascript" src="js/jquery-1.10.2.min.js"></script>
    <script language="javascript" type="text/javascript" src="js/jquery-ui-1.10.3.custom.js"></script>
    
    <link rel="stylesheet" href="css/estilo.css">
    
    <script language="javascript" type="text/javascript">
	    $(function() {
			$( "#menu" ).menu();
		});
    </script>
    <style>
		.ui-menu { width: 150px; }
	</style>
</head>

<body>
   <ul id="menu">
     	<li><a href="/Livraria/autor?operacao=listarTodos">Autor</a></li>
	    <li><a href="/Livraria/editora?operacao=listarTodos">Editora</a></li>
	    <li><a href="/Livraria/livro?operacao=listarTodos">Livros</a></li>
   </ul>
   
   
	<c:if test="${not empty erro}">
		<div style="color: red;">
			<c:out value="${erro}"></c:out>
		</div>
	</c:if>
	
	<c:if test="${not empty msg}">
		<div style="color: blue;">
			<c:out value="${msg}"></c:out>
		</div>
	</c:if>
	
	<form action="autor" method="POST">
		
		Nome: <input type="text" name="nome" value="${autor.nome}"/>
		<br/>
		<input type="submit" value="Enviar">
		
		<input type="hidden" name="operacao" value="alterar" >
		<input type="hidden" name="idAutor" value="${autor.id}">
	</form>

</body>
</html>